# Maintainer: Daniel Wallace <danielwallace at gtmanfred dot com>
# Contributor: Limao Luo <luolimao+AUR@gmail.com>

pkgname=python-jsonpointer
pkgver=2.4
pkgrel=1
pkgdesc="Identify specific nodes in a JSON document (RFC 6901)"
arch=('any')
url="https://github.com/stefankoegl/python-json-pointer"
license=('BSD')
depends=('python')
makedepends=('python-setuptools')
source=("https://github.com/stefankoegl/python-json-pointer/archive/v$pkgver/$pkgname-$pkgver.tar.gz")
sha512sums=('0d4ee2fa8bd24c4aeabce9c30df539dfb1089879c7c697bfb7bf997227e640d37dd485ef1eb9e3c4bdfdffc8b597f01b0b45180c16c29727d4afed30f573995b')

build() {
    cd python-json-pointer-$pkgver
    python setup.py build
}

check() {
    cd python-json-pointer-$pkgver
    python -m unittest
}

package() {
    cd python-json-pointer-$pkgver
    python setup.py install --prefix=/usr --root="$pkgdir"
    install -Dm644 LICENSE.txt -t "$pkgdir"/usr/share/licenses/$pkgname/
}
